<template>
	<view class="icos">
		<!-- 顶部介绍卡 -->
		<title-card :userInfo='userInfo'></title-card>
		<!-- 图标选项 -->
		<view class="items">

			<view class="cards" v-for="item in icons" @click='gotopage(item.index)'>
				<!-- <img id='imgs' :src="item.url" mode=""></img> -->
			</view>
		</view>
		<view>
			<u-popup v-model="show" mode="center" border-radius="14" width="565rpx" height="332rpx" close-icon-size="40"
				mask :close-icon-pos='right'>
				<view class="content">
					<view class="titles">
						请选择申报的场地类型
					</view>
					<view class="selects">
						<view class="img" @click="cdzz(1)">
							出土场地
						</view>
						<view class="img1" @click="cdzz(2)">
							消纳场地
						</view>
					</view>
				</view>
			</u-popup>
		</view>
	</view>
</template>

<script>
	import {
		mapState
	} from 'vuex'
	import {
		notice
	} from '@/pages/api/orderp/orderp.js'
	import titleCard from '@/components/TitleCard/TitleCard.vue'
	export default {
		data() {
			return {
				icons: [{
					url: require('@/static/shenpi.png'),
					index: '/pages/index/approval/index',
					title: '在线审核'
				}, {
					url: require('@/static/zhifa.png'),
					index: '/pages/index/listCard/home',
					title: '掌上执法'
				}],
				currentab: 0,
				show: false,
				clodeicon: true,
				right: 'bottom-right',
				app: ''
			}
		},
		components: {
			titleCard,

		},
		computed: {
			...mapState(['userInfo']),
		},
		onLoad(op) {
			var app = getApp();
			console.log('appppppppppppppp',app)
			// this.app = app;
			// ****** send PV埋点 ****** //
			app.$vm.aplus.aplus_queue.push({
				'action': 'aplus.sendPV',
				'arguments': [{
					is_auto: false
				}, {
					sapp_id: '0210802112509240',
					sapp_name: 'UUCS',
					page_id: 'index',
					page_name: '工作台',
					page_url: 'pages/index/index'
				}]
			});
			// ****** send PV埋点 ****** //
		},
		onShow() {
			
		},
		mounted() {

		},
		methods: {
			gotopage(index) {
				// uni.navigateTo({
				// 	url: '/pages/index/approval/yunshurenwu?stepsnumber=4&checkop=4&currenttab=0&id=402887ae7b45031f017b4519422d00a1&idd=202108142203300114&nodeId=2814a9cdb66a5648544894fa51d5ced8&nodeName=交警审核'
				// })
				// return;
				// console.log(index)
				uni.navigateTo({
					url: index,
					animationType: 'fade-in',
				})
				// uni.navigateTo({
				// 	url: '/pages/roadmap/index?&lat=119.5645&lng=39.65615165'
				// })
				// uni.navigateTo({
				// 	url: '/pages/index/test',
				// 	animationType: 'fade-in',
				// })

			},
			//在线申报
			cdzz(index) {
				let url = ''
				if (index == 1) {
					url = '/pages/index/declare/zzcdreport'
				} else {
					url = '/pages/index/declare/xncdreport'
				}
				this.show = false
				uni.navigateTo({
					url: url,
					animationType: 'fade-in',
				})
			},

		}
	}
</script>

<style lang="scss" scoped>
	.icos {
		width: 750rpx;

		.items {
			padding-top: 29rpx;
			padding-left: 29rpx;
			display: flex;
			flex-wrap: wrap;

			.cards {
				display: flex;
				flex-direction: column;
				justify-content: center;
				align-items: center;
				margin-right: 14rpx;
				margin-top: 14rpx;
				width: 707rpx;
				height: 377rpx;
				box-shadow: 0 2px 8px 0 rgba(0, 0, 0, 0.12);

				.title {
					color: #3E4046;
					font-size: 29rpx;
				}
			}
		}


	}

	.content {

		.titles {
			color: #363A44;
			text-align: center;
			font-size: 29rpx;
			margin-top: 76rpx;
			margin-bottom: 33rpx;
		}

		.selects {
			display: flex;
			text-align: center;
			line-height: 145rpx;
			color: #FFFFFF;
			font-size: 38rpx;

			.img {
				height: 145rpx;
				width: 239rpx;
				background-image: url(../../static/zzcd.png);
				margin-left: 29rpx;
			}

			.img1 {
				height: 145rpx;
				width: 239rpx;
				background-image: url(../../static/cdxn.png);
				margin-left: 29rpx;
			}
		}
	}


	.cards:nth-child(1) {
		background-image: url(../../static/shenpi.png);
		background-size: cover;
	}

	.cards:nth-child(2) {
		background-image: url(../../static/zhifa.png);
		background-size: cover;
	}
</style>
